This invention relates to integrated development environments (IDEs). This invention also relates to a method for editing source code in a graphical environment, where the interdependencies between components of a program are modeled and displayed in a graphical view. In particular, this invention relates to a method for editing source code directly in the graphical view where the interdependencies between components of a program are modeled.
Current integrated development environments (IDEs) typically comprise separate windows or panes for the display of the code structure in a project, and for the editing of source files. Typically, the window which displays the code structure in a project provides for a graphical, hierarchical model of the interdependencies between various components of the underlying program(s). For example, in certain object-oriented programming environments, the display may reveal which packages may be contained in a specific project, which classes or modules may be contained within such packages or projects, and which methods, functions, procedures, or other subroutines may be defined within those classes or modules. In some instances, the interactions between the various methods (functions, procedures, or other subroutines), namely, whether or not they call themselves or each other, may also be apparent from the graphical display.
In these environments, when it is necessary to read, write, or modify the source code for a particular component, a separate window will be created for this purpose. This window appears disjointed from the graphical model where the relationships between the various program components are being displayed. The user must utilize and separately examine each of the multiple windows, and navigate between them when performing an editing task. As a result, the modifications performed on the various components are not done within the context of the overall program structure.
U.S. Pat. No. 5,490,246 discloses a graphics editor which permits complex graphical images to be formed and edited. The graphics editor generates a graph with nodes that represent image fragments, image transformations, and outputs (viewable images). Each of these nodes can be displayed in a separate viewing window and may be modified. Although the interdependencies of the various components are graphically displayed, the window displaying a component is not opened directly or positioned appropriately on the graph which models the relationships between the components. Furthermore, the invention is for editing graphic images and not for editing source code.
U.S. Pat. No. 5,642,475 discloses an apparatus and method for editing multiple graphic images displayed on a screen and correlated to each other. The invention relates to hierarchically structured graphics formed from other graphics, where changes in the view of one graphic may be performed in response to changes on another graphic which it relates to. This invention does not address the fact that the component windows are being displayed out of the context of the overall hierarchy, and further, the invention is for editing graphic images and not for editing source code.
European patent application EP 753814-A2 discloses a method and apparatus for analyzing source code to determine the dynamic properties of a program. In one embodiment of the invention, a flow graph may also be generated from the output of a source code analyzer. This invention does not relate to the editing of source code, nor does it allow for such editing to occur in windows situated appropriately on the flow graph.
U.S. Pat. No. 5,671,416 discloses an apparatus and method for searching through a parse tree of source code of a program, to allow for easier and more efficient debugging and modification of the program. Although this invention relates to the editing of source code, it does not provide a graphical, abstract view of the interdependencies of the components of the program, and further, does not allow for editing of the source code directly in that view.
It will be appreciated by those skilled in the art, that program comprehension will be enhanced where the interdependencies between various components of a program are made readily apparent. Furthermore, code maintenance and development can be made easier if the scope of desired changes can be readily determined during the editing process, by providing an interface that displays the source code of a program in a view where the interdependencies of the program components are displayed.
It is an object of the present invention to provide a system where modifications performed on various components of a computer program are done directly in the context of the overall program structure.
The invention provides for a system and method that allows for the view of the interdependencies of the components of a program to be combined with a view of the source code of the program in the visual interface of a programming environment.
According to one aspect of the invention, the interdependencies of the components of a program are displayed in a graph where the nodes of the graph represent sub-components of components of the program, and where the edges of the graph represent interdependencies between the sub-components displayed as nodes. The source code of a sub-component of a component of the program can be viewed and edited in a window that replaces the node in the graph that represents the sub-component.
Thus, the present invention is directed to a system for editing a computer program which comprises a plurality of source code components. The system includes a browser, a graphical layout control accessible to and invokable by the browser to display the relationships between said source code components as interconnected nodes, and an edit control accessible to the browser. The edit control has a plurality of edit views and edit windows. Each of the edit views corresponds to a portion (which could be the entirety) of one of said source code components and each of the edit windows provides a user interface to one of the source code components corresponding to an edit view, which enables the user to edit one of said source code components.
According to a further aspect, the present invention provides a method for editing a computer program which consists of the steps of displaying to a user a hierarchical relationship between source code components of the computer program in which each component is represented as a node, and repetitively providing means to allow the user to select one of the nodes for editing and replacing the selected node with an edit window displaying the source code component in order to permit the user to edit the source code component while viewing the hierarchical relationship.
In yet a further aspect, the present invention provides a system for editing a computer program having a browser, and a graphical layout control accessible to the browser. The graphical layout control May be invoked by the browser to provide a display of relationships between components of said computer program. The system also includes an edit control accessible to the browser. The edit control provides an interface to permit a user to select a component from within the display. An edit window containing the contents of the selected component is also provided. This window replaces the selected component within the display, for the purpose of allowing the user to edit the contents of the selected component while viewing the display of relationships.
Media embodying program instructions for use in the execution in a computer to perform the invention described herein, is a further aspect of the invention.